package com.juzi.dtguize;

public class ArrayDemo1 {
    public static void main(String[] args) {
        //目标： 掌握动态初始化元素默认的规则
        //1、整型数组的元素默认值都是0
        int [] arr = new int[10];
        System.out.println(arr[9]);

        //2、字符数组的默认值也是0
        char[] chars = new char[100];
        System.out.println( chars[0]);
        System.out.println((int)chars[99]);

        //3、浮点型元素默认值是0.0
        double [] scores = new double[100];
        System.out.println(scores[0]);

        //4、布尔类型数值 false
        boolean [] booleans = new boolean[100];
        System.out.println(booleans[0]);

        //5、引用类型数值
        String[] strings = new String[100];
        System.out.println(strings[0]);
    }
}
